package com.econorma.web;

import java.io.IOException;
import java.net.URL;

import javax.servlet.RequestDispatcher;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.eclipse.jetty.http.HttpStatus;
import org.eclipse.jetty.servlet.DefaultServlet;
import org.eclipse.jetty.servlet.ServletHolder;
import org.eclipse.jetty.webapp.WebAppContext;
import org.springframework.web.servlet.ModelAndView;


public class MapServlet extends HttpServlet {
	
	private static final String TAG = MapServlet.class.getCanonicalName();
	
	@Override
	protected void doGet(HttpServletRequest req, HttpServletResponse resp)
			throws ServletException, IOException {
		
		
		 try {
			 ModelAndView model = new ModelAndView("com/resources/jsp/map");
				 
		 	 resp.getWriter().println(model);
		 	 
		    }
	        catch (Throwable e) {
	       	resp.setStatus(HttpStatus.INTERNAL_SERVER_ERROR_500);
				resp.setContentType("text/html");
				resp.getWriter().println("<html><body><font size=\"10\" color=\"red\">Si è verificato un errore :(</font></body></html>");
	        }
		
	}
	
}

